Skip to content

Conversation

@Luka-D
Copy link
Contributor

@Luka-D Luka-D commented Nov 22, 2024

Creating this PR again, this time with commit signature.

Description of the change

After running tuning locally, the results are saved in a folder /outputs. This folder is always listed as a change when I want to make commits. To solve this I have added /outputs to the .gitignore file. If it is intended to be able to commit the /outputs folder for certain reasons, please let me know and I will delete this PR.

Related issue number

No related issue.

How to verify the PR

Run tuning locally using:
python3 tuning/sft_trainer.py
--model_name_or_path Maykeye/TinyLLama-v0
--training_data_path tests/data/twitter_complaints_small.jsonl
--output_dir outputs/lora-tuning
--num_train_epochs 5
--per_device_train_batch_size 4
--gradient_accumulation_steps 4
--learning_rate 1e-5
--response_template "\n### Label:"
--dataset_text_field "output"
--use_flash_attn false
--torch_dtype "float32"
--peft_method "lora"
--r 8
--lora_dropout 0.05
--lora_alpha 16
--log_level "error"

Then, verify that your output folder isn't shown when running git status or when trying to commit using GitHub Desktop.

Was the PR tested

I ran tuning locally and checked git status, output folder was not listed as something to commit.
I ran tox -e py and had 187 passed, no failed.

  • I have added >=1 unit test(s) for every new method I have added.
  • I have ensured all unit tests pass

Signed-off-by: Luka Dojcinovic <[email protected]>
@github-actions
Copy link

Thanks for making a pull request! 😃
One of the maintainers will review and advise on the next steps.

@github-actions github-actions bot added the feat label Nov 22, 2024
@anhuong
Copy link
Collaborator

anhuong commented Nov 26, 2024

@Luka-D so this would happen to anyone depending on what you set as your output_dir. I don't think we have a convention of setting output_dir to outputs but adding this to gitignore works as well

@Luka-D
Copy link
Contributor Author

Luka-D commented Nov 27, 2024

@anhuong That's true, I'm not sure if we want to have an internal standard for output_dir when writing tutorials, examples etc. If not, I can remove this PR if needed

@kmehant
Copy link
Collaborator

kmehant commented Nov 28, 2024

I'm not sure if we want to have an internal standard for output_dir when writing tutorials, examples etc

@Luka-D I do not think we would want to compel a standard name for output_dir for tutorials or examples. Also, from a different angle there isn't any default value to output_dir in HF trainer args which we might want to adopt or have it here in .gitignore file taking it to a standard.

@Luka-D
Copy link
Contributor Author

Luka-D commented Dec 13, 2024

Since there's no standard for output_dir I'll close this PR for now

@Luka-D Luka-D closed this Dec 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants